/**
 * Copyright &copy; 2018 thinkis All rights reserved.
 */
package com.thinkis.modules.edu.entity;

import com.thinkis.common.config.Global;
import com.thinkis.modules.sys.utils.DictUtils;
import org.hibernate.validator.constraints.Length;

import com.thinkis.common.persistence.DataEntity;

/**
 * 课程类型Entity
 * @author liuzhiping
 * @version 2018-09-12
 */
public class CourseType extends DataEntity<CourseType> {
	
	private static final long serialVersionUID = 1L;
	private String name;		// 类型名称
	private int sort;    //排序
	private String status;		// 状态
	
	public CourseType() {
		super();
		this.status = Global.YES;
	}

	public CourseType(String id){
		super(id);
	}

	@Length(min=0, max=255, message="类型名称长度必须介于 0 和 255 之间")
	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public int getSort() {
		return sort;
	}

	public void setSort(int sort) {
		this.sort = sort;
	}

	@Length(min=0, max=1, message="状态长度必须介于 0 和 1 之间")
	public String getStatus() {
		return status;
	}

	public void setStatus(String status) {
		this.status = status;
	}

	public String getStatusLabel(){
		return DictUtils.getDictLabel(status,"data_status","其他");
	}
	
}